home *** CD-ROM | disk | FTP | other *** search
/ Graphics Plus / Graphics Plus.iso / general / procssng / ccs / ccs-11.lha / ccs-lib / include / header.def < prev    next >
Encoding:
Text File  |  1992-12-12  |  4.2 KB  |  123 lines

  1. /*    HEADER . DEF
  2. %
  3. %    HEADER convert for different images
  4. %
  5. %    main purpose is for convenient.
  6. %    it also convert HIPS to HIPS_2 version.
  7. %
  8. %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
  9.  
  10. This software is copyright (C) by the Lawrence Berkeley Laboratory.
  11. Permission is granted to reproduce this software for non-commercial
  12. purposes provided that this notice is left intact.
  13.  
  14. It is acknowledged that the U.S. Government has rights to this software
  15. under Contract DE-AC03-765F00098 between the U.S.  Department of Energy
  16. and the University of California.
  17.  
  18. This software is provided as a professional and academic contribution
  19. for joint exchange. Thus, it is experimental, and is provided ``as is'',
  20. with no warranties of any kind whatsoever, no support, no promise of
  21. updates, or printed documentation. By using this software, you
  22. acknowledge that the Lawrence Berkeley Laboratory and Regents of the
  23. University of California shall have no liability with respect to the
  24. infringement of other copyrights by any part of this software.
  25.  
  26. For further information about this notice, contact William Johnston,
  27. Bld. 50B, Rm. 2239, Lawrence Berkeley Laboratory, Berkeley, CA, 94720.
  28. (wejohnston@lbl.gov)
  29.  
  30. For further information about this software, contact:
  31.     Jin Guojun
  32.     Bld. 50B, Rm. 2275, Lawrence Berkeley Laboratory, Berkeley, CA, 94720.
  33.     jin@george.lbl.gov
  34.  
  35. %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
  36. %
  37. % AUTHOR:    Jin Guojun - LBL    4/1/91
  38. */
  39.  
  40. #ifndef    HHH
  41. #define    HHH
  42.  
  43. #include "stdef.h"
  44.  
  45. #if    defined    (COMMON_TOOL) || defined FITS_IMAGE
  46. #include "fits_def.h"
  47. #endif
  48.  
  49. #define    stdin_fd    0
  50. #define    stdout_fd    1
  51. #define    stderr_fd    2
  52.  
  53. #define PFBYTE          0       /* Bytes interpreted as unsigned integers */
  54. #define PFSHORT         1       /* Short integers (2 bytes) */
  55. #define PFINT           2       /* Integers (4 bytes) */
  56. #define PFFLOAT         3       /* Float's (4 bytes)*/
  57. #define PFCOMPLEX       4       /* 2 Float's interpreted as (real,imaginary) */
  58. #define PFASCII         5       /* ASCII rep, with linefeeds after each row */
  59. #define PFDOUBLE        6       /* Double's (8 byte floats) */
  60. #define PFDBLCOM        7       /* Double complex's (2 Double's) */
  61. #define PFQUAD          10      /* quad-tree encoding (Mimaging) */
  62. #define PFQUAD1         11      /* quad-tree encoding */
  63. #define PFHIST          12      /* histogram of an image (using ints) */
  64. #define PFSPAN          13      /* spanning tree format */
  65. #define PLOT3D          24      /* plot-3d format */
  66. #define PFMSBF          30      /* packed, most-significant-bit first */
  67. #define PFLSBF          31      /* packed, least-significant-bit first */
  68. #define PFSBYTE         32      /* signed bytes */
  69. #define PFUSHORT        33      /* unsigned shorts */
  70. #define PFUINT          34      /* unsigned ints */
  71. #define PFRGB           35      /* RGBRGBRGB bytes */
  72. #define PFRGBZ          36      /* RGB0RGB0RGB0 bytes */
  73. #define PFINTPYR        50      /* integer pyramid */
  74. #define PFFLOATPYR      51      /* float pyramid */
  75.  
  76. #define    IFMT_BYTE    PFBYTE
  77. #define    IFMT_SHORT    PFSHORT
  78. #define    IFMT_LONG    PFINT
  79. #define    IFMT_FLOAT    PFFLOAT
  80. #define    IFMT_DOUBLE    PFDOUBLE
  81. #define    IFMT_ASCII    PFASCII
  82. #define    IFMT_COMPLEX    PFCOMPLEX
  83. #define    IFMT_DBLCOM    PFDBLCOM
  84. #define    IFMT_HIST    12
  85. #define    IFMT_MSBF    PFMSBF
  86. #define    IFMT_LONGPYR    PFINTPYR
  87. #define    IFMT_FLOATPYR    PFFLOATPYR
  88. #define    IFMT_SGF    IFMT_BYTE
  89. #define    IFMT_SCF    PFRGB -    2
  90. #define    IFMT_ILL    PFRGB -    1
  91. #define    IFMT_ILC    PFRGB
  92. #define    IFMT_ALPHA    PFRGBZ
  93. #define    IFMT_BITMAP    PFRGB +    2
  94. #define    IFMT_SEPLANE    PFRGB +    3
  95.  
  96. #define    CFM_SGF        0    /*    Gray Scale - 256 gray levels    */
  97. #define    CFM_SCF        1    /*    8-bit Color with ColorMAP    */
  98. #define    CFM_ILL        2    /*    3 scan line 24-bit Color    */
  99. #define    CFM_ILC        3    /*    InterLeaf Cell 24-bit Color    */
  100. #define    CFM_ALPHA    4    /*    24-bit Color + Alpha channel    */
  101. #define    CFM_BITMAP    5    /*    BitMap    1 bit 2 colors    */
  102. #define    CFM_SEPLANE    6    /*    3 separate planes    */
  103.  
  104. #define    IFMT_VFFT3D    701
  105. #define    IFMT_VFFT2D    702
  106. #define    IFMT_DVFFT3D    703
  107. #define    IFMT_DVFFT2D    704
  108. #define    IFMT_VVFFT3D    705
  109. #define    IFMT_DVVFFT3D    706
  110. #define IFMT_STREAM    710
  111.  
  112. /***    Extension for more efficient    ***/
  113.  
  114. #ifndef    MType
  115. #define    PType    unsigned int
  116. #else
  117. #define    PType    unsigned MType
  118. #endif
  119. extern    PType    pread();
  120.  
  121.  
  122. #endif    HHH
  123.